#ifndef __HTTP_CLIENT_H__
#define __HTTP_CLIENT_H__

#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <arpa/inet.h>

typedef struct HTTP_INFO{
    unsigned long file_size;
    char content_type[256];
    char file_name[256];
    char ip_addr[INET_ADDRSTRLEN];
    char aliases[256];
    int status_code;
} HTTP_INFO;

typedef struct HOST_INFO{
    char host_name[256];
    char file_path[1024];
    unsigned short port;
    char new_name[256];
} HOST_INFO;

/* get请求 */
int http_get(char *url);
void get_reply_text(char *buffer);

#endif  // end of __HTTP_CLIENT_H__
